<?php
namespace ProjetA\GroupeBundle\Form;

use Symfony\Component\Form\AbstractType;
use Symfony\Component\Form\FormBuilder;
/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/**
 * Description of TextType
 *
 * @author Gael
 */
class TextType extends AbstractType {
    protected $name;
    function __construct($name, $value= null) {
        $this->name = $name;
        $this->value= $value;
    }

    public function buildForm(FormBuilder $builder, array $options)
    {
        $builder
            //->add('name','hidden',array('data' =>$this->name))
            ->add($this->name,'text',array('data'=>$this->value));
    }

    public function getName() {
        return 'projeta_groupebundle_texttype';
    }
}

?>
